﻿@using GdHotel.Data
@using GdHotel.Data.Resources
@using GdHotel.Web.Models
@model RoomModel

@{
    var language = (Language) ViewBag.Language;
    var layoutModel = (UiModel) ViewBag.LayoutModel;
    ViewBag.Title = Model.Room.RoomType.Title;
}

@section gallery{
    @if (Model != null && Model.Gallery != null)
    {
        <text>@Html.Partial("_ShowGallery", Model.PageGallery)</text>
    }
}

<div class="wrap">
    <div class="content">
        <div class="in_content down clearfix">
            <div class="block">
                <h1>@Model.Room.RoomType.Title</h1>
                <div class="in_block">
                    @Html.Raw(Model.Room.Description)
                </div>	
                @if (Model != null && Model.Gallery != null && Model.Gallery.GetLinksAsArray().Count() > 0)
                {
                    IEnumerable<string> items = Model.Gallery.GetLinksAsArray();
                    <div class="photo_block">
                        <div class="in_photo_block">								
                            <div  class="main_image shadow">
                                <div class="image_wrap">
                                    <img src="@Url.Content(items.FirstOrDefault())" width="638px" height="353px" alt="" />
                                </div>

											
                            </div>
                            <div  class="image_thumb">
                                <ul>
                                    @foreach (string item in items)
                                    {
                                        <li src="@item"><div class="shadow">
                                                            <span><img src="@item" width="178px" height="126px"  alt="" /></span>           
                                                        </div></li>
                                    }
                                </ul>
                            </div>
                        </div>								
                    </div>
                }
                <div class="in_block">
                    <h4>@Localization.RoomsEquipment:</h4>
                    @Html.Raw(Model.Room.Equipment)
                </div>	
                <h2>@Localization.RoomCost</h2>
                <div class="in_block">
                    <div class="tbl_block">
                        <table>
                            <thead>
                                <tr><th class="c1">@Localization.RoomType</th>
                                    <th class="c2">@Localization.DailyCost</th></tr>											
                            </thead>

                            <tfoot>
                                <tr><td></td></td><td></td></tr>
                            </tfoot>
                            <tbody>
                                <tr><td class="c1">@Model.Room.RoomType.Title</td>
                                    <td class="c2">$ @Model.Room.Cost</td></tr>													
                            </tbody>
                        </table>

                    </div>
                    @if (layoutModel != null && layoutModel.Note != null)
                    {
                        <text>@Html.Raw(layoutModel.Note.PaymentsInfo)</text>
                    }
                </div>
                <div class="reserve_btn_wrap">
                    <div class="reserve_btn @language.ShortName"><a href="@Url.Action("ReserveRoom", "Reservation")"></a></div>
                    <img src="@Url.Content("~/Content/Images/bell.png")" class="bell"  width="70px" height="81px" alt="" />
                </div>	
            </div>
        </div>
    </div>
    <div class="sidebar">
        <div class="in_sidebar down clearfix">
            <h2>@Localization.HotelRooms</h2>
            @Html.Partial("_RoomTypesPartial", Model.RoomTypes)
        </div>
    </div>
</div>